package com.aaa;

//import org.springframework.amqp.core.*;
//import org.springframework.beans.factory.annotation.Qualifier;
//import org.springframework.context.annotation.Bean;
//import org.springframework.context.annotation.Configuration;
//
//@Configuration
//public class RabbitmqConfig {
////
////    public static final String EXCHANGE_NAME="exchange_topic_quick";
////
////    public static final String QUEUE_NAME="quick_queue";
//
//    //定义交换机的名字
//    public static final String  EXCHANGE_NAME = "exchange_topic_quick";
//    //定义队列的名字
//    public static final String QUEUE_NAME = "quick_queue";
//
//    @Bean("bootExchange")
//    public Exchange bootExchange(){
//        return ExchangeBuilder.topicExchange(EXCHANGE_NAME).durable(true).build();
//    }
//
//    //2、声明队列
//    @Bean("bootQueue")
//    public Queue bootQueue(){
//        return new Queue(QUEUE_NAME,true);
//    }
//
//
//    //3、队列与交换机进行绑定
//    @Bean
//    public Binding bindQueueExchange(@Qualifier("bootQueue") Queue queue, @Qualifier("bootExchange") Exchange exchange){
//        return BindingBuilder.bind(queue).to(exchange).with("boot.#").noargs();
//    }
//
//}
